# Contributor: August Klein <amatcoder@gmail.com>
# Maintainer: August Klein <amatcoder@gmail.com>
pkgname=ghex
pkgver=45.1
_pkgver=${pkgver%.*}
pkgrel=0
pkgdesc="A hex editor for GNOME"
url="https://wiki.gnome.org/Apps/Ghex"
arch="all !s390x !riscv64" # gtk4.0
license="GPL-2.0-or-later"
depends="dconf"
makedepends="
	at-spi2-core-dev
	desktop-file-utils
	glib-dev
	gtk4.0-dev
	itstool
	libadwaita-dev
	meson
	"
subpackages="$pkgname-dev $pkgname-lang $pkgname-doc"
source="https://download.gnome.org/sources/ghex/$_pkgver/ghex-$pkgver.tar.xz"

build() {
	abuild-meson -Db_lto=true . output
	meson compile -C output
}

check() {
	meson test --no-rebuild --print-errorlogs -C output
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C output
}

sha512sums="
308e1dbcdab1a3277b7808f3e0f09af4609e69b263fc7b02ae7a7d71fd47f7c66f7838281b14dd8f3175ec3449dc074a17286961220216374769b790e800a92f  ghex-45.1.tar.xz
"
